import { V as g } from "./vendor-BOsc3Pjv.js";
import {
  aI as F,
  B as w,
  i as I,
  C as P,
  E as T,
  j as b,
  n as A,
  S as _,
  aB as k,
  aJ as N,
  aK as S,
  aL as E,
  aM as L,
  k as D,
  aN as $,
  e as p,
  aO as c,
  aP as O,
  v as V,
  aQ as B,
  aR as x,
  aS as R,
  aT as U,
  aU as W,
  aV as H,
  ag as d,
  aW as K,
} from "./index-Dr7F7vam.js";
const u = "_vue_desktopExternal_handler",
  M = (t, e) => {
    const s = t;
    t instanceof HTMLAnchorElement &&
      ((t.target = "_blank"), (t.rel = "noopener")),
      (s[u] = {
        handler(r) {
          q(r, s, e);
        },
      }),
      s.addEventListener("click", s[u].handler, { passive: !1 });
  },
  G = (t) => {
    const e = t;
    e[u] &&
      typeof e[u].handler == "function" &&
      e.removeEventListener("click", e[u].handler);
  };
function q(t, e, s) {
  t.preventDefault();
  let r = s.value;
  !r && e instanceof HTMLAnchorElement && (r = e.href), r && F(r);
}
const J = { bind: M, unbind: G },
  z = { type: [Array, Function], default: () => [] },
  Q = g.extend({
    components: {
      AxDropdownButton: w,
      AxIcon: I,
      AxList: P,
      AxListItem: T,
      AxButton: b,
    },
    props: {
      items: z,
      value: {
        type: [String, Number, Array, Boolean, Function, Object],
        default: null,
      },
      defaultValue: {
        type: [String, Number, Array, Boolean, Function, Object],
        default: null,
      },
      itemValue: {
        type: [String, Number, Array, Boolean, Function, Object],
        default: "value",
      },
      itemText: { type: String, default: "text" },
      itemTitle: { type: String, default: "title" },
      itemDisabled: { type: String, default: "" },
      right: { type: Boolean, default: !1 },
      left: { type: Boolean, default: !1 },
      label: { type: String, default: "Select" },
      submitProp: { type: String, default: "" },
      disabled: { type: Boolean, default: !1 },
      block: { type: Boolean, default: !0 },
      nativeStyled: { type: Boolean, default: !1 },
      markSelected: { type: Boolean, default: !1 },
    },
    data() {
      const t = { searchedText: "", timerId: null, isTimeoutEnd: !0 };
      return {
        itemsLoading: !0,
        itemsArray: this.items,
        menuOpened: !1,
        search: t,
        focusedItem: null,
        scrollToIndex: 0,
        listItemHeight: 24,
      };
    },
    computed: {
      selectedText() {
        if (this.itemsLoading) return " 加载中... ";
        if (this.value !== null && this.value !== void 0) {
          if (typeof this.value == "object") return this.value[this.itemText];
          for (const t of this.itemsArray)
            if (this.itemText && this.itemValue) {
              if (t[this.itemValue] === this.value) return t[this.itemText];
            } else if (t === this.value) return this.value;
        }
        return this.label ? this.label : "";
      },
      listStyleComputed() {
        return {
          height: `${this.listItemHeight}px`,
          lineHeight: `${this.listItemHeight}px`,
        };
      },
    },
    watch: {
      items: {
        async handler() {
          await this.resolveItems();
        },
        immediate: !0,
      },
      value(t) {
        this.focusedItem = t;
      },
    },
    methods: {
      async resolveItems() {
        if (
          ((this.itemsLoading = !0),
          (this.itemsArray =
            typeof this.itemsArray == "function"
              ? await this.itemsArray()
              : this.items),
          this.defaultValue && this.itemsArray && this.itemsArray.length)
        ) {
          for (const t of this.itemsArray)
            if (t[this.itemValue] === this.defaultValue) {
              this.select(t);
              break;
            }
        }
        this.itemsLoading = !1;
      },
      select(t) {
        this.$emit("input", this.submitProp ? t[this.submitProp] : t);
      },
      focus(t, e) {
        (this.focusedItem = t), e != null && (this.scrollToIndex = e);
      },
      getItemText(t) {
        return this.itemText ? t[this.itemText] : t;
      },
      getItemTitle(t) {
        return this.itemTitle ? t[this.itemTitle] : this.getItemText(t);
      },
      isItemSelected(t) {
        return this.value
          ? t[this.itemValue] === this.value[this.itemValue]
          : !1;
      },
      isItemFocused(t) {
        return this.focusedItem
          ? t[this.itemValue] === this.focusedItem[this.itemValue]
          : !1;
      },
      nextItem(t, e, s) {
        if (this.itemsArray && this.itemsArray.length > 0) {
          let r = 0;
          if (!t) e(this.itemsArray[r], r);
          else
            for (r = 0; r <= this.itemsArray.length - 2; r++)
              if (s(this.itemsArray[r])) {
                e(this.itemsArray[r + 1], r + 1);
                break;
              }
        }
      },
      prevItem(t, e, s) {
        if (this.itemsArray && this.itemsArray.length > 0) {
          let r = this.itemsArray.length - 1;
          if (!t) e(this.itemsArray[r], r);
          else
            for (r = 1; r <= this.itemsArray.length - 1; r++)
              if (s(this.itemsArray[r])) {
                e(this.itemsArray[r - 1], r - 1);
                break;
              }
        }
      },
      focusSelectElement() {
        if (!this.menuOpened) {
          const t = this.$refs.axSelect;
          t && t.focus();
        }
      },
      menuToggled(t) {
        this.focusSelectElement(), (this.menuOpened = t);
      },
      searchItem(t) {
        const e = () => {
          if (this.itemsArray && this.itemsArray.length > 0) {
            const s =
              this.focusedItem &&
              this.getItemText(this.focusedItem)
                .toLowerCase()
                .startsWith(this.search.searchedText.toLowerCase());
            if (this.search.isTimeoutEnd || !s)
              for (let r = 0; r <= this.itemsArray.length - 1; r++) {
                const o = this.itemsArray[r],
                  a = this.getItemText(o)
                    .toLowerCase()
                    .startsWith(this.search.searchedText.toLowerCase());
                if (!this.isItemFocused(o) && a) {
                  this.focus(o, r);
                  break;
                }
              }
          }
        };
        this.search.isTimeoutEnd
          ? ((this.search.searchedText = t),
            e(),
            (this.search.isTimeoutEnd = !1),
            (this.search.timerId = setTimeout(() => {
              this.search.isTimeoutEnd = !0;
            }, 250)))
          : ((this.search.searchedText += t),
            e(),
            clearTimeout(this.search.timerId),
            (this.search.timerId = setTimeout(() => {
              this.search.isTimeoutEnd = !0;
            }, 250)));
      },
      keyHandler(t) {
        const { keyCode: e, key: s } = t;
        e === 13
          ? (t.preventDefault(),
            this.menuOpened
              ? (this.select(this.focusedItem), (this.menuOpened = !1))
              : (this.menuOpened = !0))
          : e === 27 || e === 9
          ? (this.menuOpened = !1)
          : e === 32
          ? (this.menuOpened = !0)
          : e === 38
          ? this.menuOpened
            ? this.prevItem(this.focusedItem, this.focus, this.isItemFocused)
            : this.prevItem(this.value, this.select, this.isItemSelected)
          : e === 40
          ? this.menuOpened
            ? this.nextItem(this.focusedItem, this.focus, this.isItemFocused)
            : this.nextItem(this.value, this.select, this.isItemSelected)
          : s.length === 1 && this.menuOpened && this.searchItem(s);
      },
    },
  });
var Y = function () {
    var e = this,
      s = e._self._c;
    return (
      e._self._setupProxy,
      s(
        "div",
        {
          ref: "axSelect",
          staticClass: "ax-select",
          class: {
            "ax-select--block": e.block,
            "ax-select--empty": !e.itemsArray || e.itemsArray.length === 0,
            "ax-select--native-styled": e.nativeStyled,
          },
        },
        [
          s(
            "AxDropdownButton",
            {
              staticClass: "w-100",
              attrs: {
                "content-class": "ax-select__content",
                "use-activator-width": "",
                right: e.right,
                left: e.left,
                block: e.block,
                color: "link",
                disabled: e.disabled,
                active: e.menuOpened,
                "toggle-callback": e.menuToggled,
                "scroll-to-index": e.scrollToIndex,
                "item-height": e.listItemHeight,
                "native-styled": e.nativeStyled,
                append: "",
              },
              scopedSlots: e._u([
                {
                  key: "activator",
                  fn: function ({ active: r }) {
                    return [
                      s(
                        "AxButton",
                        {
                          staticClass: "ax-select__activator",
                          class: { "ax-select__activator--active": r },
                          attrs: { block: "", color: "link" },
                          on: {
                            keydown: function (o) {
                              return e.keyHandler(o);
                            },
                          },
                        },
                        [
                          s(
                            "div",
                            { staticClass: "d-flex align-items-center" },
                            [
                              s("span", { staticClass: "selected-text" }, [
                                e._v(e._s(e.selectedText)),
                              ]),
                              s("AxIcon", {
                                staticClass: "icon-caret icon-margin--left",
                                attrs: { name: "caret" },
                              }),
                            ],
                            1
                          ),
                        ]
                      ),
                    ];
                  },
                },
              ]),
            },
            [
              s(
                "AxList",
                {
                  staticClass: "select-items",
                  class: { "mark-selected": e.markSelected },
                  nativeOn: {
                    mouseleave: function (r) {
                      e.focusedItem = null;
                    },
                  },
                },
                e._l(e.itemsArray, function (r) {
                  return s(
                    "AxListItem",
                    {
                      key: e.itemValue ? r[e.itemValue] : r,
                      class: { disabled: e.itemDisabled && r[e.itemDisabled] },
                      attrs: {
                        disabled: e.itemDisabled ? r[e.itemDisabled] : !1,
                      },
                      nativeOn: {
                        mousemove: function (o) {
                          return e.focus(r);
                        },
                        click: function (o) {
                          return e.select(r);
                        },
                      },
                    },
                    [
                      s(
                        "div",
                        {
                          staticClass: "item",
                          class: { item__focused: e.isItemFocused(r) },
                        },
                        [
                          e.markSelected && e.isItemSelected(r)
                            ? s("AxIcon", {
                                staticClass: "icon-caret item__mark",
                                attrs: { rotate: -90, name: "caret" },
                              })
                            : e._e(),
                          s(
                            "span",
                            {
                              class: {
                                "selected-item-text":
                                  e.markSelected && e.isItemSelected(r),
                              },
                              attrs: { title: e.getItemTitle(r) },
                            },
                            [e._v(" " + e._s(e.getItemText(r)) + " ")]
                          ),
                        ],
                        1
                      ),
                    ]
                  );
                }),
                1
              ),
            ],
            1
          ),
        ],
        1
      )
    );
  },
  X = [],
  Z = A(Q, Y, X, !1, null, "b4d61c2c", null, null);
const ee = Z.exports,
  v = "axure-cloud-last-project-upload",
  { ipc: y } = window.AxureCloudNative,
  te = g.extend({
    components: {
      AxAxureLogo: _,
      AxForm: k,
      AxFormErrors: N,
      AxFormGroup: S,
      AxButton: b,
      AxIcon: I,
      AxInput: E,
      AxSelect: ee,
      AxWorkspacesToggleAll: L,
      AxPublishNotes: D,
      AxFilesystemTreeProjects: $,
    },
    directives: { desktopExternal: J },
    data() {
      const t = {
          fullName: " 创建新项目 ",
          name: "创建新项目",
          shortcut: "",
          isNewProject: !0,
        },
        e = { name: "", platform: null, width: 1024, height: 800 },
        s = async () =>
          (await K()).map((o) => {
            const { DeviceName: a, Dimensions: i, Device: n } = o;
            let l = a;
            return (
              i && (l = `${l} (${i.Width} x ${i.Height})`),
              { text: l, value: n }
            );
          }),
        r = [];
      return {
        filesystemTreeReady: !1,
        newProjectItem: t,
        defaultNewProjectName: " 未命名 ",
        fsEntries: void 0,
        enterpriseLicenseCheckFailedMessage: p,
        model: { selectedFolder: null, selectedProject: null, newProject: e },
        devices: s,
        defaultDeviceValue: c.iPhone13And14,
        errors: r,
        showAll: !1,
        publishNote: null,
        folderProjects: [],
        selectedFolderId: void 0,
      };
    },
    computed: {
      homeRouteWeb() {
        return O({ path: V.home.path });
      },
      isRpRoleViewer() {
        const { user: t, axShareConfig: e } = this.$store.state;
        return (
          !!t.userInfo &&
          !!e &&
          e.IsSubInstance &&
          t.userInfo.axureRpRole === B.Viewer
        );
      },
      enterpriseLicenseCheckFailed() {
        return this.$store.getters.enterpriseLicenseCheckFailed;
      },
      batchExportAvailableChecks() {
        return [
          { hasFailed: this.enterpriseLicenseCheckFailed, errorMessage: p },
          {
            hasFailed: this.isRpRoleViewer,
            errorMessage:
              " 查看器账户没有上传画布的权限。 请联系系统管理员请求作者权限。 ",
          },
        ];
      },
      batchExportFailure() {
        return this.batchExportAvailableChecks.find((t) => t.hasFailed);
      },
      currentUserId() {
        const { user: t } = this.$store.state;
        return t.userInfo ? t.userInfo.userId : "";
      },
      currentUserToken() {
        const { accountService: t } = this.$store.state;
        return t ? t().AuthToken : "";
      },
    },
    async created() {
      document.body.classList.add("body-fluid");
      const t = [x.Expo, x.Handoff];
      (this.fsEntries = await R(!1, t)), this.restoreLastProject();
    },
    beforeDestroy() {
      document.body.classList.remove("body-fluid");
    },
    methods: {
      onFilesystemTreeLoaded() {
        (this.filesystemTreeReady = !0), this.restoreLastProject();
      },
      async submit({
        values: { selectedProject: t, selectedFolder: e, newProject: s },
      }) {
        if (!t || !e) return;
        const r = !!t.isNewProject && !!s;
        await U(e.id, r);
        let o = t.shortcut,
          a = !1,
          i = t.name;
        if (t.isNewProject && s) {
          const l =
              !s.name || s.name === this.defaultNewProjectName ? "" : s.name,
            C = s.platform ? s.platform.value : c.iPhone13And14,
            j = {
              Name: l,
              Platform: C,
              Width: s.width,
              Height: s.height,
              FolderId: e.id,
              currentFolderId: e.id,
            },
            h = await W(j);
          if ((await H(), h && h.Vars)) {
            const { shortcut: m, name: f } = h.Vars;
            m && ((o = m), (a = !0)), f && (i = f);
          }
        }
        (o = o.toLowerCase()), localStorage.setItem(v, o);
        const n = { id: o, name: i };
        this.publishNote && (n.publishNote = JSON.stringify(this.publishNote)),
          y.send("upload-project-bunch", n, a);
      },
      cancelUpload() {
        y.send("upload-project-bunch-cancel");
      },
      restoreLastProject() {
        if (!this.fsEntries || !this.filesystemTreeReady) return;
        const t = localStorage.getItem(v);
        let e;
        if (t) {
          for (const s of this.fsEntries.rootFolder.children)
            if (((e = this.findFolderIdByShortcut(t, s)), e)) break;
        }
        (this.selectedFolderId =
          e || this.getDefaultFolderId(this.fsEntries.rootFolder.children)),
          this.selectedFolderId &&
            this.$nextTick(() => {
              const s = t && e;
              if (
                ((this.model.selectedProject = s
                  ? this.folderProjects.find((r) => d(r.shortcut, t))
                  : this.folderProjects.find((r) => r.isNewProject)),
                !s)
              ) {
                const r = this.$refs.newProjectInput;
                r && typeof r.focus == "function" && r.focus();
              }
            });
      },
      uploadDisabled(t, e, s) {
        return !t || !e || s;
      },
      projectNameOnBlur(t) {
        t.name || (t.name = this.defaultNewProjectName);
      },
      projectNameOnFocus(t) {
        t.name === this.defaultNewProjectName && (t.name = "");
      },
      isCustomWidth(t) {
        return t && t.platform
          ? t.platform.value === c.Custom || t.platform.value === c.Web
          : !1;
      },
      isCustomHeight(t) {
        return t && t.platform ? t.platform.value === c.Custom : !1;
      },
      clearErrors() {
        this.errors = [];
      },
      addError(t) {
        this.errors.push(t);
      },
      getSelectedProjectId({ selectedProject: t }) {
        return t && !t.isNewProject ? t.shortcut : "";
      },
      getSelectedFolderId({ selectedFolder: t }) {
        return t ? t.id : "";
      },
      onFolderChanged(t) {
        var s;
        const e = (s = this.model.selectedFolder) == null ? void 0 : s.id;
        t && !d(e, t.id)
          ? ((this.model.selectedFolder = t),
            this.generateFolderProjects(t),
            (this.model.selectedProject = this.folderProjects.find(
              (r) => r.isNewProject
            )))
          : (this.model.selectedFolder = null);
      },
      generateFolderProjects(t) {
        if (!this.fsEntries || !t) return;
        let e;
        for (const s of this.fsEntries.rootFolder.children)
          if (((e = this.getFolderTreeNode(s, t.id)), e)) break;
        e && (this.folderProjects = this.getProjectsFromTreeNode(e));
      },
      getDefaultFolderId(t) {
        for (const e of t) {
          if (e.defaultWorkspace) return e.id;
          if (e.children) {
            const s = this.getDefaultFolderId(e.children);
            if (s) return s;
          }
        }
      },
      getFolderTreeNode(t, e) {
        if (d(t.id, e)) return t;
        if (t.children)
          for (const s of t.children) {
            const r = this.getFolderTreeNode(s, e);
            if (r) return r;
          }
        return null;
      },
      getProjectsFromTreeNode(t) {
        const e = [this.newProjectItem];
        for (const s of t.children)
          if (d(s.filetype, "expo")) {
            const r = this.getProjectNode(s);
            e.push(r);
          }
        return e;
      },
      findFolderIdByShortcut(t, e) {
        for (const s of e.children) {
          if (d(s.id, t)) return e.id;
          if (s.children && s.children.length > 0) {
            const o = this.findFolderIdByShortcut(t, s);
            if (o) return o;
          }
        }
      },
      getProjectNode(t) {
        const e = this.stripShortcutFromName(t);
        return { shortcut: t.id, fullName: t.name, name: e };
      },
      stripShortcutFromName(t) {
        const e = ` (${t.id})`,
          s = t.name;
        let r = s;
        return s.endsWith(e) && (r = r.substring(0, s.length - e.length)), r;
      },
    },
  });
var se = function () {
    var e = this,
      s = e._self._c;
    return (
      e._self._setupProxy,
      s("div", { staticClass: "export-window" }, [
        s("div", { staticClass: "export-header desktop-app-drag" }, [
          s(
            "div",
            { staticClass: "h2 m-0" },
            [s("AxIcon", [s("AxAxureLogo", { attrs: { light: "" } })], 1)],
            1
          ),
        ]),
        s(
          "div",
          { staticClass: "ax-upload-files" },
          [
            e.batchExportFailure
              ? s("div", { staticClass: "error-message" }, [
                  s("h5", { staticClass: "m-0" }, [
                    e._v(" " + e._s(e.batchExportFailure.errorMessage) + " "),
                  ]),
                ])
              : e.isRpRoleViewer
              ? s("div", { staticClass: "error-message" }, [
                  s("h3", [
                    e._v(
                      " 查看器账户没有上传画布的权限。 "
                    ),
                  ]),
                  s("h5", [
                    e._v(
                      " 请联系系统管理员请求作者权限。 "
                    ),
                  ]),
                ])
              : [
                  s("AxForm", {
                    staticClass: "upload-files-form",
                    attrs: {
                      "hide-errors": "",
                      value: e.model,
                      submit: e.submit,
                    },
                    on: { "on-error": e.addError },
                    scopedSlots: e._u([
                      {
                        key: "default",
                        fn: function ({
                          values: r,
                          handleSubmit: o,
                          submitting: a,
                        }) {
                          return [
                            s("form", [
                              s("div", [
                                s("div", { staticClass: "form-title" }, [
                                  e._v(" 选择一个项目继续进行 "),
                                ]),
                                s(
                                  "div",
                                  { staticClass: "form-body" },
                                  [
                                    s("div", { staticClass: "row" }, [
                                      s(
                                        "div",
                                        { staticClass: "col text-end" },
                                        [
                                          s("AxWorkspacesToggleAll", {
                                            attrs: { persist: !1 },
                                            model: {
                                              value: e.showAll,
                                              callback: function (i) {
                                                e.showAll = i;
                                              },
                                              expression: "showAll",
                                            },
                                          }),
                                        ],
                                        1
                                      ),
                                    ]),
                                    s(
                                      "AxFormGroup",
                                      [
                                        s(
                                          "span",
                                          { staticClass: "input-hint-text" },
                                          [e._v(" 工作区 ")]
                                        ),
                                        s("AxFilesystemTreeProjects", {
                                          attrs: {
                                            select: e.selectedFolderId,
                                            "show-all": e.showAll,
                                            "use-storage-show-all": !1,
                                            "render-folders": !0,
                                            "render-default-all-item": !1,
                                            "select-placeholder":
                                              "Select workspace or folder",
                                          },
                                          on: {
                                            input: e.onFolderChanged,
                                            loaded: e.onFilesystemTreeLoaded,
                                          },
                                        }),
                                      ],
                                      1
                                    ),
                                    s(
                                      "AxFormGroup",
                                      [
                                        s(
                                          "span",
                                          { staticClass: "input-hint-text" },
                                          [e._v(" 项目 ")]
                                        ),
                                        s("AxSelect", {
                                          attrs: {
                                            items: e.folderProjects,
                                            "item-value": "shortcut",
                                            "item-text": "fullName",
                                            label: "Select project",
                                            "native-styled": "",
                                            "mark-selected": "",
                                          },
                                          model: {
                                            value: r.selectedProject,
                                            callback: function (i) {
                                              e.$set(r, "selectedProject", i);
                                            },
                                            expression:
                                              "values.selectedProject",
                                          },
                                        }),
                                      ],
                                      1
                                    ),
                                    r.selectedProject &&
                                    r.selectedProject.isNewProject
                                      ? s(
                                          "div",
                                          [
                                            s(
                                              "AxFormGroup",
                                              [
                                                s("AxInput", {
                                                  ref: "newProjectInput",
                                                  attrs: {
                                                    placeholder: "项目名称",
                                                    autofocus: "",
                                                  },
                                                  on: {
                                                    focus: function (i) {
                                                      return e.projectNameOnFocus(
                                                        r.newProject
                                                      );
                                                    },
                                                    blur: function (i) {
                                                      return e.projectNameOnBlur(
                                                        r.newProject
                                                      );
                                                    },
                                                  },
                                                  model: {
                                                    value: r.newProject.name,
                                                    callback: function (i) {
                                                      e.$set(
                                                        r.newProject,
                                                        "name",
                                                        i
                                                      );
                                                    },
                                                    expression:
                                                      "values.newProject.name",
                                                  },
                                                }),
                                              ],
                                              1
                                            ),
                                            s(
                                              "AxFormGroup",
                                              [
                                                s(
                                                  "span",
                                                  {
                                                    staticClass:
                                                      "input-hint-text",
                                                  },
                                                  [e._v(" 项目尺寸 ")]
                                                ),
                                                s("AxSelect", {
                                                  attrs: {
                                                    items: e.devices,
                                                    "default-value":
                                                      e.defaultDeviceValue,
                                                    "item-value": "value",
                                                    label: "Project Type",
                                                    "native-styled": "",
                                                    "mark-selected": "",
                                                  },
                                                  model: {
                                                    value:
                                                      r.newProject.platform,
                                                    callback: function (i) {
                                                      e.$set(
                                                        r.newProject,
                                                        "platform",
                                                        i
                                                      );
                                                    },
                                                    expression:
                                                      "values.newProject.platform",
                                                  },
                                                }),
                                              ],
                                              1
                                            ),
                                            e.isCustomWidth(r.newProject) ||
                                            e.isCustomHeight(r.newProject)
                                              ? s("AxFormGroup", [
                                                  s(
                                                    "div",
                                                    { staticClass: "row" },
                                                    [
                                                      s(
                                                        "div",
                                                        {
                                                          staticClass: "col-6",
                                                        },
                                                        [
                                                          e.isCustomWidth(
                                                            r.newProject
                                                          )
                                                            ? s("AxInput", {
                                                                attrs: {
                                                                  placeholder:
                                                                    "宽度",
                                                                },
                                                                model: {
                                                                  value:
                                                                    r.newProject
                                                                      .width,
                                                                  callback:
                                                                    function (
                                                                      i
                                                                    ) {
                                                                      e.$set(
                                                                        r.newProject,
                                                                        "width",
                                                                        i
                                                                      );
                                                                    },
                                                                  expression:
                                                                    "values.newProject.width",
                                                                },
                                                              })
                                                            : e._e(),
                                                        ],
                                                        1
                                                      ),
                                                      s(
                                                        "div",
                                                        {
                                                          staticClass: "col-6",
                                                        },
                                                        [
                                                          e.isCustomHeight(
                                                            r.newProject
                                                          )
                                                            ? s("AxInput", {
                                                                attrs: {
                                                                  placeholder:
                                                                    "高度",
                                                                },
                                                                model: {
                                                                  value:
                                                                    r.newProject
                                                                      .height,
                                                                  callback:
                                                                    function (
                                                                      i
                                                                    ) {
                                                                      e.$set(
                                                                        r.newProject,
                                                                        "height",
                                                                        i
                                                                      );
                                                                    },
                                                                  expression:
                                                                    "values.newProject.height",
                                                                },
                                                              })
                                                            : e._e(),
                                                        ],
                                                        1
                                                      ),
                                                    ]
                                                  ),
                                                ])
                                              : e._e(),
                                          ],
                                          1
                                        )
                                      : e._e(),
                                    s(
                                      "AxFormGroup",
                                      [
                                        s(
                                          "span",
                                          { staticClass: "input-hint-text" },
                                          [e._v(" 发布说明 ")]
                                        ),
                                        s("AxPublishNotes", {
                                          attrs: {
                                            shortcut: e.getSelectedProjectId(r),
                                            "folder-id":
                                              e.getSelectedFolderId(r),
                                            "user-id": e.currentUserId,
                                            "user-token": e.currentUserToken,
                                          },
                                          model: {
                                            value: e.publishNote,
                                            callback: function (i) {
                                              e.publishNote = i;
                                            },
                                            expression: "publishNote",
                                          },
                                        }),
                                      ],
                                      1
                                    ),
                                  ],
                                  1
                                ),
                              ]),
                              e.errors && e.errors.length > 0
                                ? s(
                                    "div",
                                    { staticClass: "upload-errors" },
                                    [
                                      s(
                                        "div",
                                        {
                                          staticClass: "upload-errors--close",
                                          on: { click: e.clearErrors },
                                        },
                                        [
                                          s("AxIcon", {
                                            attrs: { name: "chrome-close" },
                                          }),
                                        ],
                                        1
                                      ),
                                      s("AxFormErrors", {
                                        attrs: {
                                          errors: e.errors,
                                          color: "#fff",
                                        },
                                      }),
                                    ],
                                    1
                                  )
                                : e._e(),
                              s("div", [
                                s(
                                  "div",
                                  { staticClass: "form-buttons" },
                                  [
                                    s(
                                      "AxButton",
                                      {
                                        staticClass: "mb-3",
                                        attrs: {
                                          disabled: e.uploadDisabled(
                                            r.selectedFolder,
                                            r.selectedProject,
                                            a
                                          ),
                                          type: "submit",
                                          color: "upload",
                                          large: "",
                                        },
                                        on: {
                                          click: function (i) {
                                            return (
                                              i.preventDefault(),
                                              o.apply(null, arguments)
                                            );
                                          },
                                        },
                                      },
                                      [e._v(" 上传 ")]
                                    ),
                                    s(
                                      "AxButton",
                                      {
                                        attrs: {
                                          type: "button",
                                          color: "unstyled",
                                          large: "",
                                        },
                                        on: {
                                          click: function (i) {
                                            return (
                                              i.preventDefault(),
                                              e.cancelUpload.apply(
                                                null,
                                                arguments
                                              )
                                            );
                                          },
                                        },
                                      },
                                      [e._v(" 取消 ")]
                                    ),
                                  ],
                                  1
                                ),
                              ]),
                            ]),
                          ];
                        },
                      },
                    ]),
                  }),
                ],
          ],
          2
        ),
      ])
    );
  },
  re = [],
  ie = A(te, se, re, !1, null, null, null, null);
const le = ie.exports;
export { le as default };
